package org.example.managere.controller;

import org.example.managere.entity.operationdata.CompetingAircraft;
import org.example.managere.entity.feibiao.AmArchivesBase;
import org.example.managere.repository.operationdata.CompetingAircraftRepository;
import org.example.managere.repository.feibiao.AmArchivesBaseRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/test")
public class TestController {

    @Autowired
    private CompetingAircraftRepository competingAircraftRepository;

    @Autowired
    private AmArchivesBaseRepository amArchivesBaseRepository;

    @GetMapping("/operationdata")
    public List<CompetingAircraft> testOperationdata() {
        return competingAircraftRepository.findAll();
    }

    @GetMapping("/feibiao")
    public List<AmArchivesBase> testFeibiao() {
        return amArchivesBaseRepository.findAll();
    }
} 